StringScanner.SkipOverStringI Function

Syntax

Chars_Skipped as N = SkipOverStringI as n(characters as c)

Arguments

Chars_Skipped

The number of characters the offset has been moved.

characters

The text to find in the buffer.

Description

Skip over matching text (case insensitive). Returns number of characters skipped.

Discussion

The <StringScanner>.SkipOverStringI() function moves the offset to the end of the specified Text (case insensitive) and returns the number of characters that the offset has moved. The offset must be positioned at the beginning of the specified Text for the function to work.

Example

dim scanner as P
dim txt as C
txt = <<%text%
This is wonderful prose written
by a technical writer of note.
%text%
scanner = stringscanner.create(txt)
? scanner.SkipToStringI("writer")
= .T.
? scanner.SkipOverStringI("writer")
= 6
? scanner.GetToOffset()
= This is wonderful prose written
by a technical writer
? scanner.getremainder()
= of note.

See Also